	@include("user.head")
	<!-- 公共头部 -->

	<div id="content_person">
	<div class="row">
		<div class="col-xs-3">
			@include("user.uc.navigation")
		</div>
		<div class="col-xs-9">
			<div class="panel panel-default">
			  <div class="panel-heading">
			    <h3 class="panel-title">
			    	融资
			    </h3>
			  </div>
			  <div class="panel-body">
			  	<div class="row">
			  		<div class="col-xs-12">
			  			<button class="btn btn-primary pull_right" id="toFinance">
			  				<i class="fa fa-cloud-upload"></i> 我要融资
			  			</button>
			  		</div>
			  	</div>
		  	    <ul class="nav nav-tabs">
		  		  <li class="active"><a href="#technologies" data-toggle="tab" aria-expanded="true"><span class="lb-1">设备</span></a></li>
		  		  <li class=""><a href="#devices" data-toggle="tab" aria-expanded="false"><span class="lb-2">技术</span></a></li>
		  		</ul>
				<div id="myTabContent" class="tab-content">
				  <div class="tab-pane fade active in" id="technologies">
					<table class="table table-striped text-center">
						<thead>
						  <td><b>设备名称</b></td>
						  <td><b>设备型号</b></td>
						  <td><b>制造商</b></td>
						  <td><b>状态</b></td>
						  <td><b>发布时间</b></td>
						  <td><b>操作</b></td>
						</thead>
						<tbody>
							@foreach($device as $value)
							<tr>
							  <td><%$value['name']%></td>
							  <td><%$value['model']%></td>
							  <td><%$value['creator']%></td>
							  <td>
							  	@if($value['is_financing'] == 1)
							  	审核中
							  	@elseif($value['is_financing'] == 2)
							  	审核通过
							  	@endif
							  </td>
							  <td><%noSecond($value['created_at'])%></td>
							  <td>
							  	<button href="#" class="btn btn-primary" pid="<%$value['id']%>" title="详情">
							  		<i class="fa fa-eye"></i>
							  	</button>
						      	<button class="btn btn-primary edit_finance" finid="<%$value['finance']['id']%>" title="编辑">
						      		<i class="fa fa-pencil-square-o"></i>
						      	</button>
							  </td>
							</tr>
							@endforeach
						</tbody>

					</table>

				  </div>
					<div class="tab-pane fade" id="devices">
				    	<table class="table table-striped text-center">
							<thead>
						        <td><b>技术名称</b></td>
						        <td><b>开发者</b></td>
						        <td><b>状态</b></td>
						        <td><b>发布时间</b></td>
						        <td><b>操作</b></td>
							</thead>
							<tbody>
								@foreach($techs as $value)
							    <tr>
								  <td><%$value['tech_name']%></td>
								  <td><%$value['developer']%></td>
								  <td>
								  	@if($value['is_financing'] == 1)
								  	审核中
								  	@elseif($value['is_financing'] == 2)
								  	审核通过
								  	@endif
								  </td>
								  <td><%noSecond($value['created_at'])%></td>
								  <td>
								  	<button href="#" class="btn btn-primary" pid="<%$value['id']%>" title="详情">
								  		<i class="fa fa-eye"></i>
								  	</button>
							      	<button href="#" class="btn btn-primary edit_finance" finid="<%$value['finance']['id']%>" title="编辑">
							      		<i class="fa fa-pencil-square-o"></i>
							      	</button>
								  </td>
								</tr>
								@endforeach
							</tbody>
						</table>
						<div class="row text-center">

						</div>
				  	</div>
				</div>
			  </div>
			</div>
		</div>
	</div>
	</div>

	<!-- 公共底部 -->
	@include("user.footer")
	@include("user.common")
	<!-- 公共底部 -->
</body>
<script type="text/javascript">
$(".toDetail").click(function(){
	var pid = $(this).attr("pid");
	window.location.href="<%url('industry/project/detail?pid=')%>"+pid;
})

$("#toFinance").bind("click", function(){
	window.location.href="edit_finance";
})


$(".edit_finance").bind("click", function(){
	var finid = $(this).attr("finid");
	window.location.href="update_finance?finid="+finid;
})
</script>
</html>